home *** CD-ROM | disk | FTP | other *** search
/ FM Towns: Free Software Collection 9 / FM Towns Free Software Collection 9.iso / t_os / shell / igo / gosource / mdauto.c < prev    next >
Encoding:
C/C++ Source or Header  |  1994-11-16  |  2.1 KB  |  93 lines

  1. #include <stdio.h>
  2. #include <stdlib.h>
  3. #include <string.h>
  4. #include <winb.h>
  5. #include <te.h>
  6. #include <fntb.h>
  7. #include <gui.h>
  8. #include "igo.h"
  9. #include "banx.h"
  10. #include "kifuctrl.h"
  11.  
  12. int    auto_alertId = -1 ;
  13. int    auto_messageId[7] = -1 ;
  14. int    auto_icon[2] = -1 ;
  15. int    auto_bottonId[3] = -1 ;
  16. int    auto_numbox = -1 ;
  17.  
  18. /*    initDataMIAUTO:auto_bottonId[0]:MJ_DBUTTONL40の呼び出し関数    */
  19. /*  設定の関数  */
  20. int    igo_autoset(kobj, messId, argc, pev, trigger)
  21. int        kobj ;
  22. int        messId ;
  23. int        argc ;
  24. EVENT    *pev ;
  25. int        trigger ;
  26. {
  27.     igo_do_autoset();
  28.  
  29.     return NOERR ;
  30. }
  31.  
  32. /*    initDataMIAUTO:auto_bottonId[1]:MJ_DBUTTONL40の呼び出し関数    */
  33. int    igo_autocancel(kobj, messId, argc, pev, trigger)
  34. int        kobj ;
  35. int        messId ;
  36. int        argc ;
  37. EVENT    *pev ;
  38. int        trigger ;
  39. {
  40.     /*    auto_alertIdで示されるオブジェクトを消す        */
  41.     MMI_SendMessage( auto_alertId , MM_ERASE , 0 ) ;
  42.  
  43.     /*    オブジェクトをダイアログから取り外す    */
  44.     MMI_SendMessage( auto_alertId , MM_DETACH , 0 ) ;
  45.  
  46.     retunrInitMenuFunc();
  47.  
  48.     return NOERR ;
  49. }
  50.  
  51. /*    initDataMIAUTO:auto_bottonId[3]:MJ_DBUTTONL40の呼び出し関数    */
  52. /*  設定即再生の関数  */
  53. int    igo_autoexec(kobj, messId, argc, pev, trigger)
  54. int        kobj ;
  55. int        messId ;
  56. int        argc ;
  57. EVENT    *pev ;
  58. int        trigger ;
  59. {
  60.     igo_do_autoset();
  61.     igo_autorebirth();
  62.     return NOERR ;
  63. }
  64.  
  65. /*  設定の下請け関数  */
  66. int    igo_do_autoset()
  67. {
  68.     int repeat_flg, change_flg, comment_flg = 0, rebirth_speed;
  69.     int min, max, delta, ptColum; /* 使用していない */
  70.  
  71.     /*  再生オプションをセット */
  72.     repeat_flg = MTL_checkFlagObj( auto_icon[0] , MS_TOGGLE) ;
  73.     change_flg = MTL_checkFlagObj( auto_icon[1] , MS_TOGGLE) ;
  74.  
  75.     kifu_rebirth( repeat_flg, change_flg, comment_flg);
  76.     
  77.     /*    数値入力パネルの読み取り    */
  78.     MMI_SendMessage(auto_numbox, MM_GETNUMBOX, 5,
  79.                             &rebirth_speed, &min, &max, &delta, &ptColum) ;
  80.  
  81.     kifu_rebirth_speed_set( rebirth_speed);
  82.     
  83.     /*    auto_alertIdで示されるオブジェクトを消す        */
  84.     MMI_SendMessage( auto_alertId , MM_ERASE , 0 ) ;
  85.  
  86.     /*    オブジェクトをダイアログから取り外す    */
  87.     MMI_SendMessage( auto_alertId , MM_DETACH , 0 ) ;
  88.  
  89.     retunrInitMenuFunc();
  90.  
  91.     return NOERR ;
  92. }
  93.